﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TreeListSelect.aspx.cs" Inherits="Bingosoft.WebApp.Modules.SecurityConsole.Common.FunctionControl.TreeListSelect.TreeListSelect" %>
<%@ Import Namespace="Bingosoft.Modules.SecurityConsole.Common.Helper" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script type="text/javascript">
    var Global = {};
    Global.contextPath = '<%= RequestHelper.GetContextPath(Request) %>';
</script>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>树型列表选择</title>
    <meta http-equiv="cache-control" content="no-store"/>
	<meta http-equiv="Pragma" content="no-cache"/>
	<meta http-equiv="Expires" content="0"/>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    
    <web:Script ID="Script1" src="~/Scripts/jquery.js" runat="server" />
    <web:Script ID="Script2" src="~/Scripts/jquery.utils.js" runat="server" />
    <web:Script ID="Script4" src="~/Scripts/common.js" runat="server" />
    <web:Script ID="Script3" src="~/Scripts/jquery_plugins/jquery.json.js" runat="server" />

    <link id="Link3" href="~/Widgets/core/tree/ui.tree.css" rel="stylesheet" type="text/css" />
    <web:Script ID="Script8" src="~/Widgets/core/tree/ui.tree.js" runat="server" />

    <link rel="stylesheet" type="text/css" href="TreeListSelect.css" />
    <script type="text/javascript" src="TreeListSelect.js"></script>
    <script type="text/javascript" src="ListSelect.js"></script>
</head>
 <script type="text/javascript">
        var treeRootText = "<%=Request.Params["treeRootText"] %>";
        var treeRootId = "<%=Request.Params["treeRootId"] %>";
        var isTreeAsyn = "<%=Request.Params["isTreeAsyn"] %>";
        var params = "<%=Request.Params["params"] %>";
        var treeRootSqlId = "<%=Request.Params["treeRootSqlId"] %>";
        var treeChildSqlId = "<%=Request.Params["treeChildSqlId"] %>";
        var listSqlId = "<%=Request.Params["listSqlId"] %>";
        var saveService = "<%=Request.Params["saveService"] %>";
        var title = "<%=Request.Params["title"] %>";
        var listDataService = "<%=Request.Params["listDataService"] %>";
        
        var userTreeObject = new UserTreeObject();
    </script>
	<body>
		<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0" id="Table1">
			<tr>
				<td>
					<table width="100%" border="0" cellpadding="0" cellspacing="0" id="Table2">
						<tr>
							<td class="frame1_bd_01">
							</td>
							<td class="frame1_bd_02">
								<table width="*" cellpadding="0" cellspacing="0"
									class="ow_hdr_mg" id="Table5">
									<tr>
										<td class="ow_hdr_i">
											<img src="Images/ow_hdr_i.gif" border="0">
										</td>
										<td class="ow_hdr_f">
											人员选择
										</td>
									</tr>
								</table>
							</td>
							<td class="frame1_bd_03">
								<img src="Images/space.gif">
							</td>
						</tr>
					</table>
				</td>
			</tr>
			<tr>
				<td height="75%" align="center" valign="top">
					<!-- 页面主体 -->
					<div class="content">

						<table width="100%" cellpadding="0" cellspacing="0" class="layout_lr">
							<tr>
								<td class="left" id="treeviewTd">
									<div class="treeview" id="treeviewDiv" type="1">
										<h1>
											组织结构树
										</h1>
											<div id="treeview" style="padding: 0; margin: 0; padding-left: 2px;">
			                                    <div class="main" id="treeDiv" oncontextmenu="return false;"
				                                    style="width: 100%; height: 380px; overflow: auto;">
			                                    </div>
                                            </div>

									</div>
								</td>
								<td class="right" style="padding-right: 5px">
									<div class="search" style="border-top: none;">
										<!-- 查询信息 -->
										<table cellpadding="0" cellspacing="0" width="96%">
											<tr>
												<td>
													名称：<input type="text" value="" id="USER_NAME" style="width:100px"/>
												</td>
                                               
												<td>
													账号：<input type="text" value="" id="ACCOUNT"  style="width:100px"/>
												</td>

												<td>
													手机号码：<input type="text" value="" id="MOBILE" style="width:100px"/>
												</td>

												<td class="button">
													<a href="javascript:queryUsers(true);"><span> <img
																src="Images/ico_search.gif">查询</span> </a>
													<a href="javascript:" onClick="clearParam();"><span>
															<img width="15" height="14" src="Images/ico_007.gif">重置</span>
													</a>
												</td>
											</tr>
										</table>
									</div>
									<!-- 用户列表框 -->
									<div class="datalist" style="margin-top: 6px;">
										<h2>
											查询人员结果
										</h2>
										<!-- 工具栏 -->
										<div class="toolbar">
										</div>
										<div class="datagrid" align="left">
                                        
											<iframe id="userList" name="userList" frameborder=0 
												scrolling=auto style="width: 650px;" height="170px;"
												src=""></iframe>
                                                
										</div>
										<div class="pagerstyle" style="height: 35px;">
											<div class="pageinfo" id="pages1">
												共
												<font id="pageNum"></font>页/
												<font id="recordNum"></font>条记录 每页
												<select name="pageSize" id="pageSize"
													onChange="pageSizeChangeAction();">
													<option value="5" selected=selected>
														5
													</option>
													<option value="10">
														10
													</option>
													<option value="20">
														20
													</option>
												</select>
												条 跳转
												<input type="text" name="textfield" id="textfield" value="1" />
												页
												<a href="#" onClick="go(document.getElementById('textfield').value)" style="padding-right: 3px"><span>GO</span>
												</a>
												<a href="#" onClick="forwordPage(1, true);"><span
													style="height: 20px">首页</span> </a>
												<div id="pageList" style="display: inline">

												</div>
												<div style="display: inline">
													<a href="#"
														onClick="forwordPage(document.getElementById('pageNum').innerText, true);"><span
														style="height: 20px">尾页</span> </a>
												</div>
											</div>
										</div>

										<h1
											style="height: 20px; line-height: 15px; background: #dfeafb; font-weight: bold; color: #3a6683;">
											&nbsp;&nbsp;&nbsp;已选择的人
											
												<span class="search2"
													style="width: 530px; text-align: right; font-weight: normal;">
													<a style="text-decoration: none; float: right"
													href="javascript:userTreeObject.deleteSelected(document.getElementById('selectedPerson'));">
														<span>删除选择</span> </a> </span>
											
										</h1>
										<select multiple="multiple" id='selectedPerson'
											ondblclick="javascript:userTreeObject.deleteSelected(document.getElementById('selectedPerson'));"
											size="7" style="width: 100%;">
										</select>
								</td>
							</tr>
						</table>
					</div>
				</td>
			</tr>
			<tr>
				<td>
					<table width="100%" border="0" cellpadding="0" cellspacing="0" id="Table4">
						<tr>
							<td class="frame1_bd_07">
							</td>
							<td class="frame1_bd_08">
								<table cellpadding="0" cellspacing="0" class="ow_btm_mg"
									id="Table6">
									<tr>
										<td class="ow_btm_msg">
										</td>
										<td class="ow_btm_btn">
											<!------------------ 按钮 ------------------>
                                            <% if (!string.IsNullOrEmpty(Request.Params["saveService"]))
                                               {%>
												<a href="javascript:" class="combtn"
													onclick="onSave(document.getElementById('selectedPerson'))"><span
													><img src="Images/true.gif">保存</span>
												</a>
                                                <%
                                               }
                                               else
                                               {
                                                %>
												<a href="javascript:"
													onClick="return returnAction(document.getElementById('selectedPerson'));;"
													class="combtn"> <span>
														<img src="Images/true.gif">确定</span> </a>
                                               <%
                                                } 
                                                %>
											<a href="javascript:window.close();" class="combtn"> <span
												> <img
														src="Images/ico_009a.gif">关闭</span> </a>

											<!------------------END 按钮 --------------->
										</td>
									</tr>
								</table>
							</td>
							<td class="frame1_bd_09">
							</td>
						</tr>
					</table>
				</td>
			</tr>
		</table>
	</body>
</html>
